<?php
/**
 * This file is part of the jdufs project
 *
 * (c) tiglog <xq@tiglog.com>
 *
 * For the full copyright and license information, please view the LICENSE file
 * that was distributed with this source code.
 */
namespace tiglog\datatables;

use yii\db\ActiveQuery;


interface DataInterface
{

    /**
     * 定义要显示的列
     *
     * @return array
     * @author tiglog
     */
    public function columns();

    /**
     * 初始化 query
     */
    public function initQuery();

    /**
     * 搜索过滤需要自定义
     *
     * @return ActiveQuery
     * @author  tiglog
     */
    public function onFilter(ActiveQuery $query, $columns, $search);


}


// vim:ft=php:ts=4:sts=4:sw=4:et
